package com.zpark.controller;

import com.zpark.entity.patients.PatientHealthInfo;
import com.zpark.service.PatientHealthInfoService;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List;

@RestController
@RequestMapping("/patient/health")
public class PatientHealthInfoController {
    
    private final PatientHealthInfoService patientHealthInfoService;
    
    public PatientHealthInfoController(PatientHealthInfoService patientHealthInfoService) {
        this.patientHealthInfoService = patientHealthInfoService;
    }
    
    @GetMapping("/all")
    public List<PatientHealthInfo> getAllPatientHealthInfo() {
        return patientHealthInfoService.getAllPatientHealthInfo();
    }
}